package com.sailorj.medical.dao;

import java.sql.ResultSet;
import java.sql.SQLException;

import com.sailorj.medical.domain.area.Area;
import com.sailorj.medical.domain.institution.Institution;

/**
 * 农合经办机构查询Dao类
 */
public class InstitutionDao extends GenericDao<Institution> {

	@Override
	protected Institution handle(ResultSet rs) throws SQLException {
		String areacode=rs.getString("areacode");
		String agencode=rs.getString("agencode");
		String agenname=rs.getString("agenname");
		int  grade =rs.getInt("grade");
		Area area=new Area(areacode);
		Institution entity=new Institution(area, agencode, agenname, grade);
		return entity;
	}

}
